# -*- coding: cp1252 -*-
#Boa:MDIParent:MDIParentFrame1

import wx
from cadPessoas import *
from cadProdutos import *

def create(parent):
    return MDIParentFrame1(parent)

[wxID_MDIPARENTFRAME1] = [wx.NewId() for _init_ctrls in range(1)]

[wxID_MDIPARENTFRAME1FINANCEIROCAPAGAR, 
 wxID_MDIPARENTFRAME1FINANCEIROCARECEBER, 
] = [wx.NewId() for _init_coll_financeiro_Items in range(2)]

[wxID_MDIPARENTFRAME1RELATORIOSDECOMPRA, 
 wxID_MDIPARENTFRAME1RELATORIOSDEVENDA, 
] = [wx.NewId() for _init_coll_relatorios_Items in range(2)]

[wxID_MDIPARENTFRAME1MOVIMENTOCOMPRA, wxID_MDIPARENTFRAME1MOVIMENTOPVENDA, 
 wxID_MDIPARENTFRAME1MOVIMENTOVENDA, 
] = [wx.NewId() for _init_coll_movimento_Items in range(3)]

[wxID_MDIPARENTFRAME1CADASTROPESSOAS, wxID_MDIPARENTFRAME1CADASTROPRODUTOS, 
] = [wx.NewId() for _init_coll_cadastro_Items in range(2)]

class MDIParentFrame1(wx.MDIParentFrame):
    def _init_coll_movimento_Items(self, parent):
        # generated method, don't edit

        parent.Append(help='', id=wxID_MDIPARENTFRAME1MOVIMENTOCOMPRA,
              kind=wx.ITEM_NORMAL, text='Compra')
        parent.Append(help='', id=wxID_MDIPARENTFRAME1MOVIMENTOPVENDA,
              kind=wx.ITEM_NORMAL, text='Pedido de Venda')
        parent.Append(help='', id=wxID_MDIPARENTFRAME1MOVIMENTOVENDA,
              kind=wx.ITEM_NORMAL, text='Venda')
        self.Bind(wx.EVT_MENU, self.OnMovimentoCompraMenu,
              id=wxID_MDIPARENTFRAME1MOVIMENTOCOMPRA)
        self.Bind(wx.EVT_MENU, self.OnMovimentoPvendaMenu,
              id=wxID_MDIPARENTFRAME1MOVIMENTOPVENDA)
        self.Bind(wx.EVT_MENU, self.OnMovimentoVendaMenu,
              id=wxID_MDIPARENTFRAME1MOVIMENTOVENDA)

    def _init_coll_cadastro_Items(self, parent):
        # generated method, don't edit

        parent.Append(help='', id=wxID_MDIPARENTFRAME1CADASTROPESSOAS,
              kind=wx.ITEM_NORMAL, text='Pessoas')
        parent.Append(help='', id=wxID_MDIPARENTFRAME1CADASTROPRODUTOS,
              kind=wx.ITEM_NORMAL, text='Produtos')
        self.Bind(wx.EVT_MENU, self.OnCadastroPessoasMenu,
              id=wxID_MDIPARENTFRAME1CADASTROPESSOAS)
        self.Bind(wx.EVT_MENU, self.OnCadastroProdutosMenu,
              id=wxID_MDIPARENTFRAME1CADASTROPRODUTOS)

    def _init_coll_menuBar1_Menus(self, parent):
        # generated method, don't edit

        parent.Append(menu=self.cadastro, title='Cadastro')
        parent.Append(menu=self.movimento, title='Movimento')
        parent.Append(menu=self.financeiro, title='Financeiro')
        parent.Append(menu=self.relatorios, title='Relatorios')

    def _init_coll_relatorios_Items(self, parent):
        # generated method, don't edit

        parent.Append(help='', id=wxID_MDIPARENTFRAME1RELATORIOSDECOMPRA,
              kind=wx.ITEM_NORMAL, text='De Compra')
        parent.Append(help='', id=wxID_MDIPARENTFRAME1RELATORIOSDEVENDA,
              kind=wx.ITEM_NORMAL, text='De Venda')
        self.Bind(wx.EVT_MENU, self.OnRelatoriosDecompraMenu,
              id=wxID_MDIPARENTFRAME1RELATORIOSDECOMPRA)
        self.Bind(wx.EVT_MENU, self.OnRelatoriosDevendaMenu,
              id=wxID_MDIPARENTFRAME1RELATORIOSDEVENDA)

    def _init_coll_financeiro_Items(self, parent):
        # generated method, don't edit

        parent.Append(help='', id=wxID_MDIPARENTFRAME1FINANCEIROCAPAGAR,
              kind=wx.ITEM_NORMAL, text='Contas a Pagar')
        parent.Append(help='', id=wxID_MDIPARENTFRAME1FINANCEIROCARECEBER,
              kind=wx.ITEM_NORMAL, text='Contas a Receber')
        self.Bind(wx.EVT_MENU, self.OnFinanceiroCapagarMenu,
              id=wxID_MDIPARENTFRAME1FINANCEIROCAPAGAR)
        self.Bind(wx.EVT_MENU, self.OnFinanceiroCareceberMenu,
              id=wxID_MDIPARENTFRAME1FINANCEIROCARECEBER)

    def _init_utils(self):
        # generated method, don't edit
        self.menuBar1 = wx.MenuBar()

        self.cadastro = wx.Menu(title='Cadastro')

        self.movimento = wx.Menu(title='Movimento')

        self.financeiro = wx.Menu(title='Financeiro')

        self.relatorios = wx.Menu(title='Relatorios')

        self._init_coll_menuBar1_Menus(self.menuBar1)
        self._init_coll_cadastro_Items(self.cadastro)
        self._init_coll_movimento_Items(self.movimento)
        self._init_coll_financeiro_Items(self.financeiro)
        self._init_coll_relatorios_Items(self.relatorios)

    def _init_ctrls(self, prnt):
        # generated method, don't edit
        wx.MDIParentFrame.__init__(self, id=wxID_MDIPARENTFRAME1, name='',
              parent=prnt, pos=wx.Point(196, 0), size=wx.Size(900, 764),
              style=wx.DEFAULT_FRAME_STYLE | wx.VSCROLL | wx.HSCROLL,
              title='+Controle')
        self._init_utils()
        self.SetClientSize(wx.Size(892, 737))
        self.SetMenuBar(self.menuBar1)
        self.SetBackgroundColour(wx.Colour(143, 103, 7))

    def __init__(self, parent):
        self._init_ctrls(parent)

    def OnFinanceiroCapagarMenu(self, event):
        event.Skip()

    def OnFinanceiroCareceberMenu(self, event):
        event.Skip()

    def OnRelatoriosDecompraMenu(self, event):
        event.Skip()

    def OnRelatoriosDevendaMenu(self, event):
        event.Skip()

    def OnCadastroPessoasMenu(self, event):       
        cpess = cadPessoas(self)
        cpess.Show(True)

    def OnCadastroProdutosMenu(self, event):
        cprod = cadProdutos(self)
        cprod.Show(True)

    def OnMovimentoCompraMenu(self, event):
        event.Skip()

    def OnMovimentoPvendaMenu(self, event):
        event.Skip()

    def OnMovimentoVendaMenu(self, event):
        event.Skip()
